function equal(old, target) {
    let r = true;
    for (const prop in old) {
      if (typeof old[prop] === 'function' && typeof target[prop] === 'function') {
        if (old[prop].toString() !== target[prop].toString()) {
          r = false;
        }
      } else if (old[prop] !== target[prop]) {
        r = false;
      }
    }
    return r;
  }
  
  export default equal;
  